function batchPay(order_id) {
    dialog.iframeOpen(batchPayUrl + "&order_id=" + order_id + "&type_id=2&is_sql=1", "付款", 1000, 500);
}


function batchHexiao() {
    layer.confirm("确定选中的数据【核销】么？共" + layui.data('checked').select_data.length + "条", function (index) {
        $.ajax({
            type: "POST",
            dataType: "json",
            url: hexiaoUrl,
            data: {
            },
            success: function (data) {
                if (data.flag) {
                    dialog.msg(data.msg, 1);
                    setTimeout(function () {
                        window.location.reload();
                    }, 500);
                } else {
                    dialog.alert(data.msg);
                }
            }
        });
        layer.close(index);
    });
}

function batchCancelHexiao() {
    layer.confirm("确定选中的数据【取消核销】么？共" + layui.data('checked').select_data.length + "条", function (index) {
        $.ajax({
            type: "POST",
            dataType: "json",
            url: cancelHexiaoUrl,
            data: {
            },
            success: function (data) {
                if (data.flag) {
                    dialog.msg(data.msg, 1);
                    setTimeout(function () {
                        window.location.reload();
                    }, 500);
                } else {
                    dialog.alert(data.msg);
                }
            }
        });
        layer.close(index);
    });
}

